package soar.template.springboot.service.hello.configuration.job;

import javax.annotation.Resource;

import org.springframework.context.annotation.Configuration;
import org.springframework.scheduling.annotation.EnableScheduling;
import org.springframework.scheduling.annotation.Scheduled;

import soar.template.springboot.service.hello.job.ScheduleJob;

@Configuration
@EnableScheduling
class MyScheduleConfiguration
{
    @Resource
    private ScheduleJob scheduleJob;
    
    @Scheduled(fixedDelay = 10 * 1000)
    public void schedule()
    {
        scheduleJob.execute();
    }
}
